<!DOCTYPE html>
<html>
<head>
    <meta name="layout" content="main"/>
    <g:set var="entityName" value="${message(code: 'account.label', default: 'account')}"/>
    <title>散点图</title>
    <style>
        %{--设置点击侧边栏如果大于当前屏幕高度则地图会变形--}%
        #wrapper{
            min-height: 0!important;
        }
        .pointImg{
            position: absolute;
            z-index: 10;
            right: 20px;
            bottom: 155px;
        }
        .housingImg{
            position: absolute;
            z-index: 10;
            right: 20px;
            bottom: 155px;
            display: none;
        }
        .clusterImg{
            position: absolute;
            z-index: 10;
            right: 20px;
            bottom: 155px;
            display: none;
        }
    </style>
    <!-- map -->
    <asset:javascript src="newMap/libs/ol/ol.js" type="text/javascript" />
    <g:link href="../../assets/javascripts/newMap/libs/ol/ol.css" rel="stylesheet" type="text/css" />
    <asset:javascript src="newMap/libs/ol/xdmap.js" type="text/javascript" />
    <g:link href="../../assets/javascripts/newMap/libs/ol/map.css" rel="stylesheet" type="text/css" />
    <!--libs-->
    <asset:javascript src="newMap/libs/aggragation/animatedclusterlayer.js" type="text/javascript" />
    <asset:javascript src="newMap/libs/aggragation/ol.geom.convexhull.js" type="text/javascript" />
    <asset:javascript src="newMap/libs/aggragation/selectclusterinteraction.js" type="text/javascript" />
    <asset:javascript src="newMap/aggregation.js"/>
    <asset:stylesheet href="newMap/heatmap.css"/>
    <g:link href="../../assets/stylesheets/newMap/newMap.css" rel="stylesheet" type="text/css"/>
</head>
<body class="fixed-navbar fixed-sidebar">
<g:include view="map/Mapscript.gsp"/>
<div class="small-header">
    <div class="hpanel">
        <div class="panel-body">
            <div id="hbreadcrumb" class="pull-right">
                <ol class="hbreadcrumb breadcrumb">
                    <li>CINDATA PLS</li>
                    <li class="active">
                        <span>地图</span>
                    </li>
                </ol>
            </div>
            <h2 class="font-light m-b-xs">
                散点图
            </h2>
        </div>
    </div>
</div>
<g:include view="map/seachCommon.gsp"/>
<asset:javascript src="newMap/heatmap/doAggregation.js"/>
<div  id="allmap" style="position: absolute;">
    <asset:image src="pointImg.png" class="pointImg"/>
    <asset:image src="clusterImg.png" class="clusterImg"/>
    <asset:image src="housingImg.png" class="housingImg"/>
</div>
<g:javascript>
    $(function () {

        $('#datepicker').datepicker({
            language: 'zh-CN'
        });
        $('#datepicker2').datepicker({
            language: 'zh-CN'
        });
        $("#datepicker").on("changeDate", function(event) {
            $("#my_hidden_input").val(
                    $("#datepicker").datepicker('getFormattedDate')
            )
        });

        // $('#esateTable').footable();

        $('.input-group.date').datepicker({ });
        $('.input-daterange').datepicker({ });
    });
    var url ='/map/heatData';
    var blur = document.getElementById("blur");
    var radius = document.getElementById("radius");
    var zoneNumber = $("#city").val();
    if (zoneNumber == '330100') {
        center = ol.proj.transform([120.1551500000, 30.2741500000], 'EPSG:4326', 'EPSG:3857');

    } else {
        center = aggregation.getCenter(zoneNumber);
    }
    var map = xdmap.mapInit('allmap',10,center);
    aggregation.getAggregation({city:zoneNumber,currentMap:'heatMap'},50,25,10,5);
</g:javascript>
</body>
</html>
